JS$^2$: Joint Scheduling and Speculative Decoding for Efficient Agentic LLM Inference

  • 2026-11-28 08:09:25
  • Zijian Wen, Liangkun Chen, Jiamin Cao, Ennan Zhai, Songjun Huang, Xu Chen, Xiaoxi Zhang
  • 0

Abstract

LLM-powered agents execute tasks through interdependent LLM calls interleaved with tool executions, making end-to-end Job Completion Time (JCT) a central serving objective. Our measurements reveal that the dominant LLM inference bottleneck shifts from decoding latency at low concurrency to queueing delay at high concurrency. Speculative Decoding (SD) accelerates decoding but may degrade performance under heavy load. Dynamic arrivals and intermittent tool executions cause batch-size fluctuations in online agent serving. Existing Adaptive Speculative Decoding (ASD) approaches rely on reactive feedback, incur overhead when speculation is disabled, and offer limited upper-layer control. Agent-level scheduling mitigates queueing delays but overlooks the load-dependent effectiveness of SD. Our key insight is that prioritizing tasks with fewer remaining LLM requests reduces queueing delays and shortens high-batch periods, creating additional SD opportunities. We present JS$^2$, a bottleneck-aware LLM serving system that jointly optimizes SD and agent-level scheduling. JS$^2$ enables externally controllable, iteration-level switching between native SD and non-SD paths using separate CUDA Graphs, minimizing disabled-SD overhead while preserving ASD compatibility. It estimates remaining steps using explicit plans, prompt-derived execution states, and hierarchical matching of historical trajectories. JS$^2$ coordinates remaining-step-aware scheduling with load-adaptive SD selection based on offline profiling and near-future load estimation. We implement JS$^2$ on vLLM and SGLang and evaluate it across three LLMs, four workloads, three workflows, two GPU platforms, and two real-world serving traces. JS$^2$ achieves up to a 2.10$\times$ speedup in average JCT over the best baselines, while maintaining comparable tail latency and throughput. Our code is available at https://github.com/Wenz0101/JS2.

 

Quick Read (beta)

loading the full paper ...